import Vue from 'vue';
import axios from './router/axios';
import VueAxios from 'vue-axios';
import App from './App';
import router from './router/router';
import animate from 'animate.css'
import './permission'; // 权限
import './error'; // 日志
import './cache';//页面缓存
import store from './store';
import {loadStyle} from './util/util'
import * as urls from '@/config/env';
import Element from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css'
import Avue from '@smallwei/avue'
import avueUeditor from 'avue-plugin-ueditor';
import '@smallwei/avue/lib/index.css'
import {
  iconfontUrl,
  iconfontVersion
} from '@/config/env';
import i18n from './lang' // Internationalization
import './styles/common.scss';
import './styles/customcommon.scss'
import basicBlock from './components/basic-block/main'
import basicContainer from './components/basic-container/main'
import website from '@/config/website';
import Region from 'v-region'
import filter from './components/business/global-filter'
import Clipboard from 'v-clipboard'

import  a, {Descriptions} from 'element-ui'

console.log('a',a)
// console.log('Descriptions', Descriptions)
// Vue.use(Descriptions)
Vue.use(Clipboard, {

})
Vue.use(Region)
Vue.use(router);
Vue.use(VueAxios, axios);
Vue.use(animate)
Vue.use(Element)
Vue.use(Avue)
//注册全局容器
Vue.component('avueUeditor', avueUeditor);
Vue.component('basicContainer', basicContainer);
Vue.component('basicBlock', basicBlock);
// Vue.component('v-region-selects', RegionSelects)
// 加载相关url地址
Object.keys(urls).forEach(key => {
  Vue.prototype[key] = urls[key];
});
// 加载website
Vue.prototype.website = website;
// 动态加载阿里云字体库
iconfontVersion.forEach(ele => {
  loadStyle(iconfontUrl.replace('$key', ele));
});

Vue.config.devtools = true
Vue.config.productionTip = false;

new Vue({
  router,
  store,
  i18n,
  render: h => h(App)
}).$mount('#app')
